package top.ffhome.common.core.mybatisplus.service;


import com.baomidou.mybatisplus.core.conditions.Wrapper;

import java.io.Serializable;
import java.util.Collection;
import java.util.List;

public interface IBaseService<T> {
    boolean insert(T entity);

    boolean updateById(T entity);

    boolean deleteById(Serializable id);

    boolean deleteByIds(Collection<? extends Serializable> idList);

    boolean delete(Wrapper<T> queryWrapper);

    T selectById(Serializable id);

    T selectOne(Wrapper<T> queryWrapper);

    List<T> selectList(T query);

    List<T> selectList(Wrapper<T> queryWrapper);

    void clearCache();
}